package com.tcd.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.tcd.pojo.Permission;

import java.util.List;

/**
 * <p>
 * 权限表 服务类
 * </p>
 *
 * @author space
 * @since 2021-05-21
 */
public interface PermissionService extends IService<Permission> {
    List<Permission> getUserPermission(Integer uid);

    List<Permission> getPermissionFilter(Integer pageIndex, Integer pageSize, String name, Integer[] levels, Integer parentId);

    Integer getPermissionFilterCount(String name, Integer level, Integer parentId);

    List<Permission> getPermissionTree(Integer[] levels);

    Integer addPermission(Permission permission);

    Integer updatePermission(Permission permission);

    Integer delPermissions(Integer[] ids);

    List<Permission> getUserPermissionNoTree(int uid);
}
